<td><input type="checkbox" name="id[]" value="{$vo.id}"></td>
<td style="text-align: left">
    {php}
        $user = Db::name('admin_user')->where('id', $vo['user_id'])->find();
        $driverPhone = $user['mobile'];
        $userName = '';
        if($user){
            $userName = $user['realname'];
        }
    {/php}
    {if !empty($user)}
        <a title="详细资料" href="javascript:;" onclick="driverInfo({$vo.user_id})" style="text-decoration:none" class="ml-5">
        <!--司机用户名-->
            {php}echo $vo['id'].':'.$userName;{/php}
        </a>
    {else /}
        用户信息不存在
    {/if}
</td>
<td>
    {if !empty($driverPhone)}
        {$driverPhone}
    {/if}
</td>
<td style="text-align: left">{$vo.id_card | default="未填写身份证号"}</td>
<td style="text-align: left">
    {$vo.plate_number|default="未填写车牌号"}
</td>
<td>{$vo.order_num}</td>
{php}
    $totalOrders = 0; // 订单总量
    $totalGoods = 0; // 好评数
    $totalBads = 0; // 差评数
    $totalFeedBack = 0; // 好评率
    $totalnotEvaluated = 0; // 未评价
    if($listData){
        foreach($listData as $keys=>$vals){
            if($vals['id'] == $vo['id']){
                $totalOrders = $vals['totalOrders'];
                $totalGoods = $vals['totalGoods'];
                $totalBads = $vals['totalBads'];
                $totalnotEvaluated = $vals['totalnotEvaluated'];
                $totalFeedBack = $vals['totalFeedBack'];
            }
        }
    }
{/php}
<td>{php} echo $totalOrders;{/php}</td>
<td>{php} echo $totalGoods;{/php}</td>
<td>{php} echo $totalBads;{/php}</td>
<td>{php} echo $totalnotEvaluated;{/php}</td>
<td>{php} echo $totalFeedBack;{/php}</td>
<td>
    {php}
        $dispatchOrderCount = Db::name('dispatch_traveler_group')
                            ->where('driver_user_id',$vo['user_id'])
                            ->where('dispatch_group_status','accounts')
                            ->where('is_reach_standard',1)
                            ->count();
        echo $dispatchOrderCount;
    {/php}
</td>